#include <stdio.h>
#include <string.h>

int main(){
    char str[]="http://www.baidu.com/";
    char str2[]="https://www.baidu.com/";
    char *c;
    c=(char*)memchr(str,'w',strlen(str));
    printf("The index of w is: %ld\n",(c-str)/sizeof(char));
    int n;
    n=memcmp(str,str2,5);
    printf("%d\n",n);
    memcpy(str,str2,5);
    printf("%s\n",str);
    memmove(str,str2,5);
    printf("%s\n",str);
    memset(str2,'!',6);
    printf("%s\n",str2);
    return 0;
}
